function heateorSssCallAjax(e){if(typeof jQuery!="undefined"){e()}else{heateorSssGetScript("https://code.jquery.com/jquery-latest.min.js",e)}}
function heateorSssGetScript(e,t){var n=document.createElement("script");n.src=e;var r=document.getElementsByTagName("head")[0],i=false;n.onload=n.onreadystatechange=function(){if(!i&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){i=true;t();n.onload=n.onreadystatechange=null;r.removeChild(n)}};r.appendChild(n)}
function heateorSssDetermineWhatsappShareAPI(a){if(a)return-1!=navigator.userAgent.indexOf("Mobi")?"api.whatsapp.com":"web.whatsapp.com";var p=jQuery("i.heateorSssWhatsappBackground a").attr("href");return void 0!==p?-1!=navigator.userAgent.indexOf("Mobi")?(jQuery("i.heateorSssWhatsappBackground a").attr("href",p.replace("web.whatsapp.com","api.whatsapp.com")),"api.whatsapp.com"):(jQuery("i.heateorSssWhatsappBackground a").attr("href",p.replace("api.whatsapp.com","web.whatsapp.com")),"web.whatsapp.com"):""}
function heateorSssMoreSharingPopup(elem, postUrl, postTitle, twitterTitle){
postUrl=encodeURIComponent(postUrl);
concate='
';
var heateorSssMoreSharingServices={
facebook:{
title:"Facebook",
locale:"en-US",
redirect_url:"https://www.facebook.com/sharer.php?u=" + postUrl + "&t=" + postTitle + "&v=3",
},
twitter:{
title:"Twitter",
locale:"en-US",
redirect_url:"https://twitter.com/intent/tweet?text=" + (twitterTitle ? twitterTitle:postTitle) + " " + postUrl,
},
linkedin:{
title:"Linkedin",
locale:"en-US",
redirect_url:"https://www.linkedin.com/shareArticle?mini=true&url=" + postUrl + "&title=" + postTitle,
},
parler:{
title:"Parler",
locale:"en-US",
redirect_url:"https://parler.com/new-post?message=" + postTitle + "&url=" + postUrl
},
pinterest:{
title:"Pinterest",
locale:"en-US",
redirect_url:"https://pinterest.com/pin/create/button/?url=" + postUrl + "&media=${media_link}&description=" + postTitle,
bookmarklet_url:"javascript:void((function(){var e=document.createElement('script');e.setAttribute('type','text/javascript');e.setAttribute('charset','UTF-8');e.setAttribute('src','//assets.pinterest.com/js/pinmarklet.js?r='+Math.random()*99999999);document.body.appendChild(e)})());"
},
CopyLink:{
title:"Copy Link",
locale:"en-US",
redirect_url:"",
bookmarklet_url:""
},
Diaspora:{
title:"Diaspora",
locale:"en-US",
redirect_url:"https://joindiaspora.com/bookmarklet?url=" + postUrl + "&title=" + postTitle + "&v=1"
},
Douban:{
title:"Douban",
locale:"en-US",
redirect_url:"https://www.douban.com/share/service?name="+postTitle+"&href="+postUrl+"&image=&updated=&bm=&url="+postUrl+"&title="+postTitle+"&sel="
},
Draugiem:{
title:"Draugiem",
locale:"en-US",
redirect_url:"https://www.draugiem.lv/say/ext/add.php?link="+postUrl+"&title="+postTitle
},
Facebook_Messenger:{
title:"Facebook Messenger",
locale:"en-US",
redirect_url:"https://www.facebook.com/dialog/send?app_id=1904103319867886&display=popup&link="+postUrl+"&redirect_uri="+postUrl
},
Google_Classroom:{
title:"Google Classroom",
locale:"en-US",
redirect_url:"https://classroom.google.com/u/0/share?url="+postUrl
},
Kik:{
title:"Kik",
locale:"en-US",
redirect_url:"https://www.kik.com/send/article/?app_name=Share&text=&title="+postTitle+"&url="+postUrl
},
Papaly:{
title:"Papaly",
locale:"en-US",
redirect_url:"https://papaly.com/api/share.html?url="+postUrl+"&title="+postTitle
},
Refind:{
title:"Refind",
locale:"en-US",
redirect_url:"https://refind.com/?url="+postUrl
},
Skype:{
title:"Skype",
locale:"en-US",
redirect_url:"https://web.skype.com/share?url="+postUrl
},
SMS:{
title:"SMS",
locale:"en-US",
bookmarklet_url:"sms:?&body="+postTitle+" "+postUrl
},
Trello:{
title:"Trello",
locale:"en-US",
redirect_url:"https://trello.com/add-card?mode=popup&url="+postUrl+"&name="+postTitle+"&desc="
},
Viber:{
title:"Viber",
locale:"en-US",
bookmarklet_url:"
},
Threema:{
title:"Threema",
locale:"en-US",
bookmarklet_url:"th
},
Telegram:{
title:"Telegram",
locale:"en-US",
redirect_url:"https://telegram.me/share/url?url="+postUrl+"&text="+postTitle
},
email:{
title:"Email",
locale:"en-US",
redirect_url:"mailto:?subject=" + postTitle + "&body=Link:" + postUrl,
},
reddit:{
title:"Reddit",
locale:"en-US",
redirect_url:"http://reddit.com/submit?url=" + postUrl + "&title=" + postTitle,
},
float_it:{
title:"Float it",
locale:"en-US",
redirect_url:"http://www.designfloat.com/submit.php?url=" + postUrl + "&title=" + postTitle,
},
google_mail:{
title:"Google Gmail",
locale:"en-US",
redirect_url:"https://mail.google.com/mail/?ui=2&view=cm&fs=1&tf=1&su=" + postTitle + "&body=Link:" + postUrl,
},
gentlereader:{
title:"GentleReader",
locale:"en-US",
redirect_url:"https://app.gentlereader.com/bookmark?url=" + postUrl,
},
google_bookmarks:{
title:"Google Bookmarks",
locale:"en-US",
redirect_url:"http://www.google.com/bookmarks/mark?op=edit&bkmk=" + postUrl + "&title=" + postTitle,
},
digg:{
title:"Digg",
locale:"en-US",
redirect_url:"http://digg.com/submit?phase=2&url=" + postUrl + "&title=" + postTitle,
},
printfriendly:{
title:"PrintFriendly",
locale:"en-US",
redirect_url:"http://www.printfriendly.com/print?url=" + postUrl,
},
print:{
title:"Print",
locale:"en-US",
redirect_url:"http://www.printfriendly.com/print?url=" + postUrl,
bookmarklet_url:"javascript:window.print()"
},
tumblr:{
title:"Tumblr",
locale:"en-US",
redirect_url:"https://www.tumblr.com/widgets/share/tool?posttype=link&canonicalUrl=" + postUrl + "&title=" + postTitle + "&caption=",
bookmarklet_url:"javascript:var d=document,w=window,e=w.getSelection,k=d.getSelection,x=d.selection,s=(e?e():(k)?k():(x?x.createRange().text:0)),f='http://www.tumblr.com/share',l=d.location,e=encodeURIComponent,p='?v=3&u='+e(l.href) +'&t='+e(d.title) +'&s='+e(s),u=f+p;try{if(!/^(.*\\.)?tumblr[^.]*$/.test(l.host))throw(0);tstbklt();}catch(z){a=function(){if(!w.open(u,'t','toolbar=0,resizable=0,status=1,width=450,height=430'))l.href=u;};if(/Firefox/.test(navigator.userAgent))setTimeout(a,0);else a();}void(0);"
},
vk:{
title:"Vkontakte",
locale:"ru",
redirect_url:"https://vk.com/share.php?url=" + postUrl + "&title=" + postTitle,
},
evernote:{
title:"Evernote",
locale:"en-US",
redirect_url:"https://www.evernote.com/clip.action?url=" + postUrl + "&title=" + postTitle,
bookmarklet_url:"javascript:(function(){EN_CLIP_HOST='http://www.evernote.com';try{var x=document.createElement('SCRIPT');x.type='text/javascript';x.src=EN_CLIP_HOST+'/public/bookmarkClipper.js?'+(new Date().getTime()/100000);document.getElementsByTagName('head')[0].appendChild(x);}catch(e){location.href=EN_CLIP_HOST+'/clip.action?url='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title);}})();"
},
amazon_us_wish_list:{
title:"Amazon Wish List",
locale:"en-US",
redirect_url:"http://www.amazon.com/wishlist/add?u=" + postUrl + "&t=" + postTitle,
bookmarklet_url:"javascript:(function(){var w=window,l=w.location,d=w.document,s=d.createElement('script'),e=encodeURIComponent,x='undefined',u='http://www.amazon.com/gp/wishlist/add';if(typeof s!='object')l.href=u+'?u='+e(l)+'&t='+e(d.title);function g(){if(d.readyState&&d.readyState!='complete'){setTimeout(g,200);}else{if(typeof AUWLBook==x)s.setAttribute('src',u+'.js?loc='+e(l)),d.body.appendChild(s);function f(){(typeof AUWLBook==x)?setTimeout(f,200):AUWLBook.showPopover();}f();}}g();}())"
},
wordpress_blog:{
title:"WordPress",
locale:"en-US",
redirect_url:"http://www.addtoany.com/ext/wordpress/press_this?linkurl=" + postUrl + "&linkname=" + postTitle,
},
whatsapp:{
title:"Whatsapp",
locale:"en-US",
bookmarklet_url:"https://" + heateorSssDetermineWhatsappShareAPI(true) + "/send?text=" + postTitle + " " + postUrl,
},
diigo:{
title:"Diigo",
locale:"en-US",
redirect_url:"http://www.diigo.com/post?url=" + postUrl + "&title=" + postTitle,
},
yc_hacker_news:{
title:"Hacker News",
locale:"en-US",
redirect_url:"http://news.ycombinator.com/submitlink?u=" + postUrl + "&t=" + postTitle,
},
box_net:{
title:"Box.net",
locale:"en-US",
redirect_url:"https://www.box.net/api/1.0/import?url=" + postUrl + "&name=" + postTitle + "&import_as=link",
},
aol_mail:{
title:"AOL Mail",
locale:"en-US",
redirect_url:"http://webmail.aol.com/25045/aol/en-us/Mail/compose-message.aspx?subject=" + postTitle + "&body=" + postUrl,
},
yahoo_mail:{
title:"Yahoo Mail",
locale:"en-US",
redirect_url:"http://compose.mail.yahoo.com/?Subject=" + postTitle + "&body=Link:" + postUrl,
},
instapaper:{
title:"Instapaper",
locale:"en-US",
redirect_url:"http://www.instapaper.com/edit?url=" + postUrl + "&title=" + postTitle,
},
plurk:{
title:"Plurk",
locale:"en-US",
redirect_url:"http://www.plurk.com/m?content=" + postUrl + "&qualifier=shares",
},
aim:{
title:"AIM",
locale:"en-US",
redirect_url:"http://share.aim.com/share/?url=" + postUrl + "&title=" + postTitle,
},
viadeo:{
title:"Viadeo",
locale:"en-US",
redirect_url:"http://www.viadeo.com/shareit/share/?url=" + postUrl + "&title=" + postTitle,
},
pinboard_in:{
title:"Pinboard",
locale:"en-US",
redirect_url:"http://pinboard.in/add?url=" + postUrl + "&title=" + postTitle,
},
blogger_post:{
title:"Blogger Post",
locale:"en-US",
redirect_url:"http://www.blogger.com/blog_this.pyra?t=&u=" + postUrl + "&l&n=" + postTitle,
},
typepad_post:{
title:"TypePad Post",
locale:"en-US",
redirect_url:"http://www.typepad.com/services/quickpost/post?v=2&qp_show=ac&qp_title=" + postTitle + "&qp_href=" + postUrl + "&qp_text=" + postTitle,
},
buffer:{
title:"Buffer",
locale:"en-US",
redirect_url:"http://bufferapp.com/add?url=" + postUrl + "&text=" + postTitle,
},
flipboard:{
title:"Flipboard",
locale:"en-US",
redirect_url:"https://share.flipboard.com/bookmarklet/popout?v=2&url=" + postUrl + "&title=" + postTitle,
},
pocket:{
title:"Pocket",
locale:"en-US",
redirect_url:"https://readitlaterlist.com/save?url=" + postUrl + "&title=" + postTitle,
},
fark:{
title:"Fark",
locale:"en-US",
redirect_url:"http://cgi.fark.com/cgi/fark/submit.pl?new_url=" + postUrl,
},
fintel:{
title:"Fintel",
locale:"en-US",
redirect_url:"https://fintel.io/submit?url=" + postUrl,
},
yummly:{
title:"Yummly",
locale:"en-US",
redirect_url:"http://www.yummly.com/urb/verify?url=" + postUrl + "&title=" + postTitle,
},
app_net:{
title:"App.net",
locale:"en-US",
redirect_url:"https://account.app.net/login/",
},
balatarin:{
title:"Balatarin",
locale:"en-US",
redirect_url:"https://www.balatarin.com/login",
},
bibSonomy:{
title:"BibSonomy",
locale:"en-US",
redirect_url:"http://www.bibsonomy.org/login",
},
Bitty_Browser:{
title:"Bitty Browser",
locale:"en-US",
redirect_url:"http://www.bitty.com/manual/?contenttype=&contentvalue=" + postUrl,
},
Blinklist:{
title:"Blinklist",
locale:"en-US",
redirect_url:"http://blinklist.com/blink?t=" + postTitle + "&d=&u=" + postUrl,
},
BlogMarks:{
title:"BlogMarks",
locale:"en-US",
redirect_url:"http://blogmarks.net/my/new.php?mini=1&simple=1&title=" + postTitle + "&url=" + postUrl,
},
Bookmarks_fr:{
title:"Bookmarks.fr",
locale:"en-US",
redirect_url:"http://www.bookmarks.fr/Connexion/?action=add&address=" + postUrl + "&title=" + postTitle,
},
BuddyMarks:{
title:"BuddyMarks",
locale:"en-US",
redirect_url:"http://buddymarks.com/login.php?bookmark_title=" + postTitle + "&bookmark_url=" + postUrl + "&bookmark_desc=&bookmark_tags=",
},
Care2_news:{
title:"Care2 News",
locale:"en-US",
redirect_url:"http://www.care2.com/passport/login.html?promoID=10&pg=http://www.care2.com/news/compose?sharehint=news&share[share_type]news&bookmarklet=Y&share[title]=" + postTitle + "&share[link_url]=" + postUrl + "&share[content]=",
},
Diary_Ru:{
title:"Diary.Ru",
locale:"en-US",
redirect_url:"http://www.diary.ru/?newpost&title=" + postTitle + "&text=" + postUrl,
},
Folkd:{
title:"Folkd",
locale:"en-US",
redirect_url:"http://www.folkd.com/page/social-bookmarking.html?addurl=" + postUrl,
},
Hatena:{
title:"Hatena",
locale:"en-US",
redirect_url:"http://b.hatena.ne.jp/bookmarklet?url=" + postUrl + "&btitle=" + postTitle,
},
Jamespot:{
title:"Jamespot",
locale:"en-US",
redirect_url:"//my.jamespot.com/",
},
Kakao:{
title:"Kakao",
locale:"en-US",
redirect_url:"https://story.kakao.com/share?url=" + postUrl,
},
Kindle_It:{
title:"Kindle_It",
locale:"en-US",
redirect_url:"//fivefilters.org/kindle-it/send.php?url=" + postUrl,
},
Known:{
title:"Known",
locale:"en-US",
redirect_url:"https://withknown.com/share/?url=" + postUrl + "&title=" + postTitle,
},
Line:{
title:"Line",
locale:"en-US",
redirect_url:"https://social-plugins.line.me/lineit/share?url=" + postUrl,
},
LiveJournal:{
title:"LiveJournal",
locale:"en-US",
redirect_url:"http://www.livejournal.com/update.bml?subject=" + postTitle + "&event=" + postUrl,
},
Mail_Ru:{
title:"Mail.Ru",
locale:"en-US",
redirect_url:"https://connect.mail.ru/share?share_url=" + postUrl,
},
Mendeley:{
title:"Mendeley",
locale:"en-US",
redirect_url:"https://www.mendeley.com/sign-in/",
},
Meneame:{
title:"Meneame",
locale:"en-US",
redirect_url:"https://www.meneame.net/submit.php?url=" + postUrl,
},
MeWe:{
title:"MeWe",
locale:"en-US",
redirect_url:"https://mewe.com/share?link=" + postUrl,
},
Mix:{
title:"Mix",
locale:"en-US",
redirect_url:"https://mix.com/mixit?url=" + postUrl,
},
Mixi:{
title:"Mixi",
locale:"en-US",
redirect_url:"https://mixi.jp/share.pl?mode=login&u=" + postUrl,
},
MySpace:{
title:"MySpace",
locale:"en-US",
redirect_url:"https://myspace.com/post?u=" + encodeURIComponent(postUrl) + "&t=" + postTitle + "&l=3&c=" + postTitle,
},
Netvouz:{
title:"Netvouz",
locale:"en-US",
redirect_url:"http://www.netvouz.com/action/submitBookmark?url=" + postUrl + "&title=" + postTitle + "&popup=no&description=",
},
Odnoklassniki:{
title:"Odnoklassniki",
locale:"en-US",
redirect_url:"https://connect.ok.ru/dk?cmd=WidgetSharePreview&st.cmd=WidgetSharePreview&st.shareUrl=" + postUrl + "&st.client_id=-1",
},
Outlook_com:{
title:"Outlook.com",
locale:"en-US",
redirect_url:"https://mail.live.com/default.aspx?rru=compose?subject=" + postTitle + "&body=" + postUrl + "&lc=1033&id=64855&mkt=en-us&cbcxt=mai",
},
Protopage_Bookmarks:{
title:"Protopage_Bookmarks",
locale:"en-US",
redirect_url:"http://www.protopage.com/add-button-site?url=" + postUrl + "&label=&type=page",
},
Pusha:{
title:"Pusha",
locale:"en-US",
redirect_url:"//www.pusha.se/posta?url=" + postUrl,
},
Qzone:{
title:"Qzone",
locale:"en-US",
redirect_url:"http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=" + postUrl,
},
Rediff_MyPage:{
title:"Rediff MyPage",
locale:"en-US",
redirect_url:"//share.rediff.com/bookmark/addbookmark?bookmarkurl=" + postUrl + "&title=" + postTitle,
},
Renren:{
title:"Renren",
locale:"en-US",
redirect_url:"//www.connect.renren.com/share/sharer?url=" + postUrl + "&title=" + postTitle,
},
Sina_Weibo:{
title:"Sina Weibo",
locale:"en-US",
redirect_url:"http://service.weibo.com/share/share.php?url=" + postUrl + "&title=" + postTitle,
},
SiteJot:{
title:"SiteJot",
locale:"en-US",
redirect_url:"http://www.sitejot.com/loginform.php?iSiteAdd=&iSiteDes=",
},
Slashdot:{
title:"Slashdot",
locale:"en-US",
redirect_url:"//slashdot.org/submission?url=" + postUrl,
},
StockTwits:{
title:"StockTwits",
locale:"en-US",
redirect_url:"https://stocktwits.com/widgets/share?body=" + postTitle + " " + postUrl,
},
Svejo:{
title:"Svejo",
locale:"en-US",
redirect_url:"https://svejo.net/story/submit_by_url?url=" + postUrl + "&title=" + postTitle + "&summary=",
},
Symbaloo_Feeds:{
title:"Symbaloo_Feeds",
locale:"en-US",
redirect_url:"//www.symbaloo.com/",
},
Tuenti:{
title:"Tuenti",
locale:"en-US",
redirect_url:"https://www.tuenti.com/share?p=b5dd6602&url=" + postUrl,
},
Twiddla:{
title:"Twiddla",
locale:"en-US",
redirect_url:"//www.twiddla.com/New.aspx?url=" + postUrl + "&title=" + postTitle,
},
Webnews:{
title:"Webnews",
locale:"en-US",
redirect_url:"//www.webnews.de/login",
},
Wykop:{
title:"Wykop",
locale:"en-US",
redirect_url:"//www.wykop.pl/dodaj?url=" + postUrl + "&title=" + postTitle,
},
Xing:{
title:"Xing",
locale:"en-US",
redirect_url:"https://www.xing.com/spi/shares/new?cb=0&url=" + postUrl,
},
Yoolink:{
title:"Yoolink",
locale:"en-US",
redirect_url:"//yoolink.to/addorshare?url_value=" + postUrl + "&title=" + postTitle,
}};
var heateorSssMoreSharingServicesHtml='
';
for(var i in heateorSssMoreSharingServices){
var tempTitle=heateorSssCapitaliseFirstLetter(heateorSssMoreSharingServices[i].title.replace(/[_. ]/g, ""));
heateorSssMoreSharingServicesHtml +=' ';
}
heateorSssMoreSharingServicesHtml +=concate;
var mainDiv=document.createElement('div');
mainDiv.innerHTML=heateorSssMoreSharingServicesHtml;
mainDiv.setAttribute('id', 'heateor_sss_sharing_more_providers');
var bgDiv=document.createElement('div');
bgDiv.setAttribute('id', 'heateor_sss_popup_bg');
jQuery('body').append(mainDiv).append(bgDiv);
document.getElementById('heateor_sss_popup_bg').onclick=document.getElementById('heateor_sss_sharing_popup_close').onclick=function(){
mainDiv.parentNode.removeChild(mainDiv);
bgDiv.parentNode.removeChild(bgDiv);
}}
if(heateorSssHorizontalSharingCountEnable||heateorSssVerticalSharingCountEnable){
heateorSssLoadEvent(
function(){
heateorSssCallAjax(function(){
heateorSssGetSharingCounts();
});
}
);
}
function heateorSssFilterSharing(val){
jQuery('ul.mini li a').each(function(){
if(jQuery(this).text().toLowerCase().indexOf(val.toLowerCase())!=-1){
jQuery(this).parent().css('display', 'block');
}else{
jQuery(this).parent().css('display', 'none');
}});
};
var heateorSssFacebookTargetUrls=[];
function heateorSssGetSharingCounts(){
var targetUrls=[];
jQuery('.heateor_sss_sharing_container').each(function(){
if(typeof jQuery(this).attr('heateor-sss-no-counts')=='undefined'){
var currentTargetUrl=jQuery(this).attr('heateor-sss-data-href');
if(currentTargetUrl!=null&&jQuery.inArray(currentTargetUrl, heateorSssUrlCountFetched)==-1){
targetUrls.push(currentTargetUrl);
heateorSssUrlCountFetched.push(currentTargetUrl);
}}
});
if(targetUrls.length==0){
return;
}
jQuery.ajax({
type:'GET',
dataType:'json',
url:heateorSssSharingAjaxUrl,
data:{
action:'heateor_sss_sharing_count',
urls:targetUrls,
},
success:function(data, textStatus, XMLHttpRequest){
if(data.status==1){
if(data.facebook){
heateorSssFacebookTargetUrls=data.facebook_urls;
}
for(var i in data.message){
var sharingContainers=jQuery("div[heateor-sss-data-href='"+i+"']");
jQuery(sharingContainers).each(function(){
var totalCount=0;
for(var j in data.message[i]){
var sharingCount=parseInt(data.message[i][j])||0;
var targetElement=jQuery(this).find('.heateor_sss_'+j+'_count');
if(jQuery(targetElement).attr('sss_st_count')){
sharingCount=parseInt(sharingCount) + parseInt(jQuery(targetElement).attr('sss_st_count'));
}
totalCount +=parseInt(sharingCount);
if(sharingCount < 1){ continue; }
jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount)).css({'visibility':'visible', 'display':'block'});
if(( typeof heateorSssReduceHorizontalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){
jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('float', 'left');
}
if(( typeof heateorSssReduceHorizontalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){
jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('marginTop', '0');
}}
var totalCountContainer=jQuery(this).find('.heateorSssTCBackground'), totalShares=heateorSssCalculateApproxCount(totalCount);
jQuery(totalCountContainer).each(function(){
var containerHeight=jQuery(this).css('height');
jQuery(this).html('').css('visibility', 'visible');
});
});
}
if(heateorSssFacebookTargetUrls.length!=0){
heateorSssFetchFacebookShares(heateorSssFacebookTargetUrls);
}}
}});
}
function heateorSssFetchFacebookShares(targetUrls){
var loopCounter=0;
for(var i in targetUrls){
for(var j in targetUrls[i]){
loopCounter++;
heateorSssFBShareJSONCall(targetUrls[i][j], loopCounter, targetUrls[0].length*targetUrls.length, targetUrls[0][j]);
}}
}
function heateorSssFBShareJSONCall(targetUrl, loopCounter, targetUrlsLength, dataHref){
jQuery.getJSON('//graph.facebook.com/?id=' + targetUrl, function(data){
if(data.share&&data.share.share_count >=0){
var sharingContainers=jQuery("div[heateor-sss-data-href='"+dataHref+"']");
jQuery(sharingContainers).each(function(){
var targetElement=jQuery(this).find('.heateor_sss_facebook_count');
var facebookBackground=jQuery(this).find('i.heateorSssFacebookBackground');
var sharingCount=parseInt(data.share.share_count);
if(jQuery(targetElement).attr('sss_st_count')!==undefined){
sharingCount +=parseInt(jQuery(targetElement).attr('sss_st_count'));
}
if(sharingCount > 0){
if(typeof jQuery(facebookBackground).attr('heateor-sss-fb-shares')=='undefined'){
jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount)).css({'visibility':'visible', 'display':'block'});
jQuery(facebookBackground).attr('heateor-sss-fb-shares', sharingCount);
}else if(typeof jQuery(facebookBackground).attr('heateor-sss-fb-shares')!='undefined'){
var tempShareCount=parseInt(jQuery(facebookBackground).attr('heateor-sss-fb-shares'));
jQuery(facebookBackground).attr('heateor-sss-fb-shares', sharingCount + tempShareCount);
jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount + tempShareCount));
}
if(( typeof heateorSssReduceHorizontalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){
jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('float', 'left');
}
if(( typeof heateorSssReduceHorizontalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){
jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('marginTop', '0');
}
var totalCountContainer=jQuery(this).find('.heateorSssTCBackground');
jQuery(totalCountContainer).each(function(){
var totalShareCountElem=jQuery(this).find('.heateorSssTotalShareCount');
var totalShareCount=jQuery(totalShareCountElem).text();
var newTotalCount=heateorSssCalculateActualCount(totalShareCount) + sharingCount;
jQuery(totalShareCountElem).text(heateorSssCalculateApproxCount(newTotalCount));
jQuery(this).find('.heateorSssTotalShareText').text(newTotalCount==0||newTotalCount > 1 ? heateorSssSharesText:heateorSssShareText);
});
}});
}
if(loopCounter==targetUrlsLength){
setTimeout(function(){
var facebookShares={};
for(var i in heateorSssFacebookTargetUrls[0]){
var sharingContainers=jQuery("div[heateor-sss-data-href='"+heateorSssFacebookTargetUrls[0][i]+"']");
jQuery(sharingContainers).each(function(){
var facebookCountElement=jQuery(this).find('.heateor_sss_facebook_count');
var facebookCountElementBg=jQuery(this).find('i.heateorSssFacebookBackground');
var shareCountString=typeof jQuery(facebookCountElementBg).attr('heateor-sss-fb-shares')!='undefined' ? jQuery(facebookCountElementBg).attr('heateor-sss-fb-shares').trim():'';
if(shareCountString!=''){
var shareCount=parseInt(heateorSssCalculateActualCount(shareCountString));
if(jQuery(facebookCountElement).attr('sss_st_count')!==undefined){
var startingCount=parseInt(jQuery(facebookCountElement).attr('sss_st_count').trim());
shareCount=Math.abs(shareCount - startingCount);
}
facebookShares[heateorSssFacebookTargetUrls[0][i]]=shareCount;
return;
}});
}
if(!jQuery.isEmptyObject(facebookShares)){
heateorSssSaveFacebookShares(facebookShares);
}}, 1000);
}});
}
function heateorSssSaveFacebookShares(facebookShares){
jQuery.ajax({
type:'GET',
dataType:'json',
url:heateorSssSharingAjaxUrl,
data:{
action:'heateor_sss_save_facebook_shares',
share_counts:facebookShares,
},
success:function(data, textStatus, XMLHttpRequest){}});
}
function heateorSssCalculateApproxCount(sharingCount){
if(sharingCount > 999&&sharingCount < 10000){
sharingCount=(Math.round(sharingCount/100))/10 + 'K';
}else if(sharingCount > 9999&&sharingCount < 100000){
sharingCount=(Math.round(sharingCount/100))/10 + 'K';
}else if(sharingCount > 99999&&sharingCount < 1000000){
sharingCount=(Math.round(sharingCount/100))/10 + 'K';
}else if(sharingCount > 999999){
sharingCount=(Math.round(sharingCount/100000))/10 + 'M';
}
return sharingCount;
}
function heateorSssCalculateActualCount(sharingCount){
if(sharingCount.indexOf('K') > 0){
sharingCount=sharingCount.replace('K', '') * 1000;
}else if(sharingCount.indexOf('M') > 0){
sharingCount=sharingCount.replace('M', '') * 1000000;
}
return parseInt(sharingCount);
}
function heateorSssCapitaliseFirstLetter(e){
return e.charAt(0).toUpperCase() + e.slice(1)
}
jQuery(function(){
var heateorSssWhatsappJSAPI=heateorSssDetermineWhatsappShareAPI(false);
var classes=['heateor_sss_vertical_sharing', 'heateor_sss_vertical_counter'];
for(var i=0; i < classes.length; i++){
if(jQuery('.' + classes[i]).length){
jQuery('.' + classes[i]).each(function(){
var verticalSharingHtml=jQuery(this).html();
if(jQuery(this).attr('style').indexOf('right') >=0){
var removeClass='heateorSssPushIn', margin='Right', alignment='right', addClass='heateorSssPullOut';
}else{
var removeClass='heateorSssPullOut', margin='Left', alignment='left', addClass='heateorSssPushIn';
}
jQuery(this).html(verticalSharingHtml + '');
});
}}
if(heateorSssMobileStickySharingEnabled==1){
if(jQuery('div.heateor_sss_vertical_sharing').length){
jQuery(document.body).append("");
}}
var heateorSssClipboard=new ClipboardJS('.heateorSssCopyLinkBackground, .heateorSssCopyLinkShare, .heateorSssCopyLinkSvg', {
text:function(trigger){
if(jQuery(trigger).hasClass('heateorSssCopyLinkShare')){
var element=trigger.parentElement.parentElement.parentElement.parentElement;
var url=jQuery(element).attr("data-href")||"";
}else if(jQuery(trigger).hasClass('heateorSssCopyLinkSvg')){
var element=trigger.parentElement.parentElement.parentElement.parentElement;
var url=jQuery(element).attr("heateor-sss-data-href")||"";
if(!url){
var element=trigger.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement;
var url=jQuery(element).attr("data-href")||"";
}}
return url;
}});
heateorSssClipboard.on('success', function(e){
alert(heateorSssCopyLinkMessage);
});
});
function heateorSssHideSharing(elem, removeClass, addClass, margin, alignment){
var animation={}, counter=jQuery(elem).parent().hasClass('heateor_sss_vertical_counter'), offset=parseInt(jQuery(elem).parent().css('width')) + 10 - (counter ? 16:0);
var ssOffset=jQuery(elem).parent().attr('ss-offset');
if(ssOffset){
var savedOffset=parseInt(ssOffset);
}else{
var savedOffset=(counter ? heateorSssCounterOffset:heateorSssSharingOffset);
}
if(jQuery(elem).attr('title')=='Hide'){
animation[alignment]="-=" + (offset + savedOffset);
jQuery(elem).parent().animate(animation, 400, function(){
jQuery(elem).removeClass(removeClass).addClass(addClass).attr('title', 'Share');
if(counter){
var cssFloat=alignment=='left' ? 'right':'left';
jQuery(elem).css('float', cssFloat);
}else{
jQuery(elem).css('margin' + margin, offset + 'px')
}});
}else{
animation[alignment]="+=" + (offset + savedOffset);
jQuery(elem).parent().animate(animation, 400, function(){
jQuery(elem).removeClass(addClass).addClass(removeClass).attr('title', 'Hide');
if(counter){
jQuery(elem).css('float', alignment);
}else{
jQuery(elem).css('margin' + margin, '0px');
}});
}}
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(this,function(){return o={},r.m=n=[function(t,e){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var o=window.getSelection(),r=document.createRange();r.selectNodeContents(t),o.removeAllRanges(),o.addRange(r),e=o.toString()}return e}},function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var o=this;function r(){o.off(t,r),e.apply(n,arguments)}return r._=e,this.on(t,r,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,r=n.length;o0}});else{var n=[];r.prototype.THROTTLE_TIMEOUT=100,r.prototype.POLL_INTERVAL=null,r.prototype.USE_MUTATION_OBSERVER=!0,r.prototype.observe=function(t){if(!this._observationTargets.some((function(e){return e.element==t}))){if(!t||1!=t.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:t,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},r.prototype.unobserve=function(t){this._observationTargets=this._observationTargets.filter((function(e){return e.element!=t})),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},r.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},r.prototype.takeRecords=function(){var t=this._queuedEntries.slice();return this._queuedEntries=[],t},r.prototype._initThresholds=function(t){var e=t||[0];return Array.isArray(e)||(e=[e]),e.sort().filter((function(t,e,n){if("number"!=typeof t||isNaN(t)||t<0||t>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return t!==n[e-1]}))},r.prototype._parseRootMargin=function(t){var e=(t||"0px").split(/\s+/).map((function(t){var e=/^(-?\d*\.?\d+)(px|%)$/.exec(t);if(!e)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(e[1]),unit:e[2]}}));return e[1]=e[1]||e[0],e[2]=e[2]||e[0],e[3]=e[3]||e[1],e},r.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(i(t,"resize",this._checkForIntersections,!0),i(e,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in t&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(e,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},r.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,s(t,"resize",this._checkForIntersections,!0),s(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},r.prototype._checkForIntersections=function(){var e=this._rootIsInDom(),n=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(r){var i=r.element,s=h(i),c=this._rootContainsTarget(i),u=r.entry,a=e&&c&&this._computeTargetAndRootIntersection(i,n),l=r.entry=new o({time:t.performance&&performance.now&&performance.now(),target:i,boundingClientRect:s,rootBounds:n,intersectionRect:a});u?e&&c?this._hasCrossedThreshold(u,l)&&this._queuedEntries.push(l):u&&u.isIntersecting&&this._queuedEntries.push(l):this._queuedEntries.push(l)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},r.prototype._computeTargetAndRootIntersection=function(n,o){if("none"!=t.getComputedStyle(n).display){for(var r,i,s,c,a,l,p,f,d=h(n),g=u(n),_=!1;!_;){var v=null,m=1==g.nodeType?t.getComputedStyle(g):{};if("none"==m.display)return;if(g==this.root||g==e?(_=!0,v=o):g!=e.body&&g!=e.documentElement&&"visible"!=m.overflow&&(v=h(g)),v&&(r=v,i=d,s=void 0,c=void 0,a=void 0,l=void 0,p=void 0,f=void 0,s=Math.max(r.top,i.top),c=Math.min(r.bottom,i.bottom),a=Math.max(r.left,i.left),l=Math.min(r.right,i.right),f=c-s,!(d=(p=l-a)>=0&&f>=0&&{top:s,bottom:c,left:a,right:l,width:p,height:f})))break;g=u(g)}return d}},r.prototype._getRootRect=function(){var t;if(this.root)t=h(this.root);else{var n=e.documentElement,o=e.body;t={top:0,left:0,right:n.clientWidth||o.clientWidth,width:n.clientWidth||o.clientWidth,bottom:n.clientHeight||o.clientHeight,height:n.clientHeight||o.clientHeight}}return this._expandRectByRootMargin(t)},r.prototype._expandRectByRootMargin=function(t){var e=this._rootMarginValues.map((function(e,n){return"px"==e.unit?e.value:e.value*(n%2?t.width:t.height)/100})),n={top:t.top-e[0],right:t.right+e[1],bottom:t.bottom+e[2],left:t.left-e[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},r.prototype._hasCrossedThreshold=function(t,e){var n=t&&t.isIntersecting?t.intersectionRatio||0:-1,o=e.isIntersecting?e.intersectionRatio||0:-1;if(n!==o)for(var r=0;r